<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="../include/base.jsp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
	<title>CRM——task</title>
	
	<link rel="stylesheet" type="text/css" href="<%=basePath%>css/bootstrap.min.css" />
	
	<link href="<%=basePath%>css/all.css" media="screen" rel="stylesheet" type="text/css" />
	<link href="<%=basePath%>css/application.css" media="print" rel="stylesheet" type="text/css" />
	<link href="<%=basePath%>css/blue.css" media="screen" rel="stylesheet" title="Theme" type="text/css" />
 
	
	<script src="<%=basePath%>js/ga.js" async="" type="text/javascript"></script>
	<script src="<%=basePath%>js/application-114d9a8373cd197d7265335db95e1a0a.js" type="text/javascript"></script>

	<script src="<%=basePath%>My97DatePicker/WdatePicker.js" type="text/javascript"></script>
	
	<style type="text/css" media="screen">
	
	
	</style>
   
   
   
</head>

<body class="clearfix overview narrow_page_with_sidebar_outside webkit  windows"  onloadnot="setupZoom()">
  <div id="quick_show_window" style="display: none">
    <div class="quick_show_window_position">
      <div class="quick_show_window_wrapper">
        <div class="quick_show_window_content">
        </div>
      </div>
    </div>
  </div>

  <div id="task_flash" style="display: none">
    <div class="inner_task_flash">
    </div>
  </div>

   <!-- 添加新任务的弹出框 -->
	<div class="modal hide" id="taskModal">
	
		<form accept-charset="UTF-8" action="<%=basePath %>/task/save_new.action" class="simple_form new_schedule" data-remote="true" id="task_form" method="post" novalidate="novalidate">
			
			<div style="margin:0;padding:0;display:inline">
				<input name="utf8" value="✓" type="hidden">
				<input name="authenticity_token" value="629Tr3qO+/ORB7Tal3EqMPPivFwAU4hBIUks4kXRpkI=" type="hidden">
			</div>
			
			<input id="context" name="context" value="tasks" type="hidden">
			<input id="schedule_contact_id" name="schedule[contact_id]" type="hidden">
			<input id="schedule_chance_id" name="schedule[chance_id]" type="hidden">
			<input id="schedule_kase_id" name="schedule[kase_id]" type="hidden">
			<input id="schedule_parent_id" name="schedule[parent_id]" type="hidden">
			<input id="form_user_id" name="user_id" type="hidden">
			<input id="filter_task_category_id" name="filter_task_category_id" type="hidden">
			
			<div class="modal-header">
				<a class="close" data-dismiss="modal">×</a>
				<h3>添加一个任务</h3>
			</div>
			
			<div class="modal-body">
				
				<div class="control-group string required">
					<div class="controls">
						<input class="string required span5" id="schedule_name" name="schedule[name]" size="50" type="text">
					</div>
				</div>
			
				<div class="control-group string optional">
					<label class="string optional control-label" for="schedule_frame">到期时间？</label>
					<div class="controls">
						<select id="task_frame" name="schedule[frame]" onchange="change_task_frame($(this).val(), '#calendar_date_start','#calendar_date_end')">
							<option value="today" selected="selected">今天</option>
							<option value="tomorrow">明天</option>
							<option value="this_week">本周</option>
							<option value="next_week">下周</option>
							<option value="later">以后</option>
							<option value="calendar">设置具体时间 ...</option>
						</select>
						
					</div>

				</div>	
				
				<span id="calendar_date_select" >
					<input id = "calendar_date_start" name = "task.starttime" type = "text"  
						onClick="WdatePicker({readOnly:true,lang:'zh-cn',dateFmt:'yyyy-MM-dd  HH:mm:ss',minDate:'%y-%M-%d'})"     
						class="Wdate span2" placeholder="请输入开始时间" style=" width:200px ;display:none; "/>   
					
					<input id = "calendar_date_end" name = "task.endtime" type = "text" 
						onClick="WdatePicker({readOnly:true,lang:'zh-cn',dateFmt:'yyyy-MM-dd  HH:mm:ss',minDate:'#F{$dp.$D(\'calendar_date_start\')}'})"
						class="Wdate span2" placeholder="请输入截止时间" style=" width:200px ;display:none; "/>   			
					
				</span>
			
				<div class="control-group integer optional">
					<label class="integer optional control-label" for="schedule_category_id">选择一个分类</label>
					
					<div class="controls">
						<select data="TaskCategory" id="schedule_category_id" name="schedule[category_id]" onchange="changeCategory(this)">
							<option selected="selected" value="">无</option>
							<option value="29942">电话</option>
							<option value="29943">邮件</option>
							<option value="29944">传真</option>
							<option value="29945">面谈</option>
							<option value="29946">感谢</option>
							<option value="29947">试用</option>
							<option value="new">添加分类 ...</option>
						</select>
						<a href="<%=basePath%>task/tasknotice.action">编辑分类</a>
					</div>
					
				</div>	
				
				<div class="control-group select optional">
					<label class="select optional control-label" for="schedule_assigned_to_id">谁负责？</label>
					<div class="controls">
						<select class="select optional" id="schedule_assigned_to_id" name="schedule[assigned_to_id]">
							<option value="6721" selected="selected">我</option>
						</select>
					</div>
				</div>
					
				<div class="control-group string optional checkbox">
					<div class="controls">
						<input name="schedule[privacy]" value="private" type="hidden">
						<input id="schedule_privacy" name="schedule[privacy]" value="public" type="checkbox"> 
						同事可以看见这个任务
					</div>
				</div>		
			
			
			</div>
			
			<div class="modal-footer" style="text-align:left;">
				<input class="btn btn-primary" name="commit" value="添加这个任务" type="submit">
				<a href="#" class="btn" data-dismiss="modal">取消</a>
			</div>
		
		</form>

	</div>

	
	
		<script type="text/javascript" charset="utf-8">
		$("#taskModal").on('shown', function() {
			$('#task_name').focus()
			validate_form('#task_form', true)
		})
		$('#taskModal').on('hidden', function () {
			$('#schedule_parent_id').val('');
	  })
	</script>
	<!-- 添加新任务的弹出框 -->
	
	
	
	
  
  
	<div id="app_header">
	<div class="background"></div>
	<div class="boundary">
		<div id="upgrade_bar"></div>
		<div id="inner_header_wrapper">
			<a href="/" id="app_logo">
			<img alt="Logo-topleft" src="img/logo-topleft.png" style="padding-top: 8px;" />
			</a>
			<table id="page_actions">
				<tr>
					<td class="tiny">
						<div class="menu_container">
								<span class="action">
									<a href="/people/new" behavior="return_to">
										<span>添加联系</span>
									</a>
								</span>
						</div>
					
					</td>
					<td class="tiny">		
						<div class="menu_container">
							<span class="action">
								<a href="#taskModal" class="btn btn-primary" data-toggle="modal" >
									<span>新的任务</span>
								</a>
								
								
								
								
							</span>
						</div>
					</td>
					<td class="long">
						<div id="search_wrapper">
							<div class="quick_find">
								<div class="field" style="position:relative;">
									<input type="text" id="sidebar_live_search" name="term" title="a contact, case, deal, or tag..."/>
								</div>
							</div>
						</div>
					</td>
				</tr>
			</table>

			
			
			
			<div id="global_links_container">
				<div class="menu_container">
			      <a href="#" class="name menu_target">
			        设置
			        <span>▼</span>
			      </a>
			      <div id="balloon_global_links" class="balloon center menu_content ">
						<div class="balloon_pointer">
							<div class="balloon_arrow menu_target"></div>
							<div class="balloon_arrow_border"></div>
						</div>
						<div class="balloon_wrapper">
							<div class="balloon_content">
								<ul class="global_links">
								<li><a href="#" class="">用户</a></li>
								<li><a href="#" class="">密码重置</a></li>
								<li><a href="#" class="">分组</a></li>
								</ul>
							</div>
						</div>
					</div>
				</div>
           </div>
		</div>
	</div>
</div>


	<div id="wrapper">
	<div id="inner_wrapper">
		<div id="main_body" class="column">
			<div id="blank_slate" class="clearfix">  
			</div>
			
		
		 <div id="screen_body">
        <!-- page sidebar -->
        <div id="page_sidebar">
			<div class="liner">
            
				<div class="sidebox_wrapper">
					<div class="liner">
						<div class="sidebox closedbox">
					<!-- 右边 -->	
			
						<div class="well">
							<div class="title">订阅您的日程安排</div>
							
							<p>
								您可以使用 Google Calendar, Apple iCal, Mozzila Calendar 等支持 iCalendar 格式的工具来 <a href="https://1344495893.workxp.info/tasks/subscription">订阅您的日程安排</a>。
							</p>
						</div>
						
						<div class="well">
							<div class="title">通过邮件创建任务</div>
							
							<p>
								您可以发送邮件到<a href="https://1344495893.workxp.info/profiles#dropbox">投件箱</a>，WorkXP会帮你创建一个任务，邮件的主题将会成为任务的内容。
							</p>
						</div>
					<!-- 右边 -->	
						
						
						
						</div>
					</div>
				</div>

			</div>
        </div>
        <!--// page sidebar -->

        <!-- page -->
        <div id="page">

            <!-- page header -->
			
            <div id="page_header_wrapper">
              
			   
				<div id="page_header">
					 
					<div class="page_header">
					
						<ul class="nav nav-tabs " style = "height:3px;">
						  <li class="active"><a href="#home" data-toggle="tab">待完成任务</a></li>
						  <li><a href="#profile" data-toggle="tab">已完成任务</a></li>
						  <li><a href="#messages" data-toggle="tab">分配给我的任务</a></li>
						  
						
						</ul>
					
					</div>

				</div>
				
            </div>
			
            <!--// page header -->

            <!-- page contents -->
            <div id="page_contents_wrapper" class="clearfix">

              <!-- main column -->
              <div id="page_main_column" class="column">
                <div class="liner">
                   <!-- 自己写的主要代码区 -->
					<div>

					<div class="tab-content">
					  <div class="tab-pane active" id="home">Div1</div>
					  <div class="tab-pane" id="profile">Div2</div>
					  <div class="tab-pane" id="messages">Div3</div>
					 
					</div>








					</div>
					 <!-- 自己写的主要代码区 -->
                </div>
              </div>
              <!--// main column -->

            </div>
            <!--// page contents -->
          
        </div>
        <!--// page -->
      </div>
		
		
		
    <div style="margin-top: 30px"> </div>        
		</div>
		<div id="global_sidebar" class="column">
		<div class="liner">
			<div id="global_nav">
			<ul>
			<li class="dashboard"><a href="/" class="selected">最新动态</a></li>
			<li class="parties"><a href="/parties" class="">联系 <span class='stat'>0人</span></a></li>
			<li class="tasks"><a href="/tasks" class="">任务<span class='stat'>无今天</span></a></li>
			<li class="deals"><a href="/deals" class="">交易 <span class='stat'>无</span></a></li>
			<li class="dashboard"><a href="/" class="selected">营销</a></li>
			</ul>
			</div>
          <div id="recent_items"><hr/>
			<h4>最近浏览</h4>
			<div class="recent_items">
				<a href="/tags/2399793" class="recent_item ">
				<span class="sprite avatar blank_avatar tag " style="background: url(https://d1a993iq9azmzq.cloudfront.net/rev_0621f90/images/highrise_sprites.png) no-repeat -168px -148px; width: 32px; padding-top: 32px; " title="大客户" id="">大客户</span>
				<span class="recent_name">大客户</span>
				<span class="recent_desc"></span>
				</a>
			</div>
			</div>
		</div>
    </div>
    </div>
</div>

  <hr style="display: none;" />
	<div id="preloaded_images" style="position:absolute; height:0px; overflow:hidden;">
		<img alt="Dots-white" src="img/dots-white.gif" />
		<img alt="Dots-black" src="img/dots-black.gif" />
	</div>
 
	
	
	
	
</body>
</html>
	

